package com.explorati.design_pattern.structural.proxy.dynamicproxy;

import com.explorati.design_pattern.structural.proxy.IOrderService;
import com.explorati.design_pattern.structural.proxy.Order;
import com.explorati.design_pattern.structural.proxy.OrderServiceImpl;

public class Test {

	public static void main(String[] args) {
		Order order = new Order();
		order.setUserId(1);

		IOrderService orderServiceDynamicProxy = (IOrderService) new OrderServiceDynamicProxy(new OrderServiceImpl())
				.bind();
		orderServiceDynamicProxy.saveOrder(order);
	}
}
